package com.wz.project.stock.stockdetail.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.wz.project.stock.stockdetail.mapper.BasStockDetailMapper;
import com.wz.project.stock.stockdetail.domain.BasStockDetail;
import com.wz.project.stock.stockdetail.service.IBasStockDetailService;
import com.wz.common.utils.text.Convert;

/**
 * 子库存查询Service业务层处理
 * 
 * @author wld
 * @date 2023-10-17
 */
@Service
public class BasStockDetailServiceImpl implements IBasStockDetailService 
{
    @Autowired
    private BasStockDetailMapper basStockDetailMapper;

    /**
     * 查询子库存查询
     * 
     * @param uuid 子库存查询ID
     * @return 子库存查询
     */
    @Override
    public BasStockDetail selectBasStockDetailById(String fbarcode)
    {
        return basStockDetailMapper.selectBasStockDetailById(fbarcode);
    }

    /**
     * 查询子库存查询列表
     * 
     * @param basStockDetail 子库存查询
     * @return 子库存查询
     */
    @Override
    public List<BasStockDetail> selectBasStockDetailList(BasStockDetail basStockDetail)
    {
        return basStockDetailMapper.selectBasStockDetailList(basStockDetail);
    }
    @Override
    public List<BasStockDetail> selectBasStockDetailList2(BasStockDetail basStockDetail)
    {
        return basStockDetailMapper.selectBasStockDetailList2(basStockDetail);
    }

    /**
     * 新增子库存查询
     * 
     * @param basStockDetail 子库存查询
     * @return 结果
     */
    @Override
    public int insertBasStockDetail(BasStockDetail basStockDetail)
    {
        return basStockDetailMapper.insertBasStockDetail(basStockDetail);
    }
    public int insertBasStockDetailfinish(BasStockDetail basStockDetail)
    {
        return basStockDetailMapper.insertBasStockDetailfinish(basStockDetail);
    }
    /**
     * 修改子库存查询
     * 
     * @param basStockDetail 子库存查询
     * @return 结果
     */
    @Override
    public int updateBasStockDetail(BasStockDetail basStockDetail)
    {
        return basStockDetailMapper.updateBasStockDetail(basStockDetail);
    }

    /**
     * 删除子库存查询对象
     * 
     * @param ids 需要删除的数据ID
     * @return 结果
     */
    @Override
    public int deleteBasStockDetailByIds(String ids)
    {
        return basStockDetailMapper.deleteBasStockDetailByIds(Convert.toStrArray(ids));
    }

    /**
     * 删除子库存查询信息
     * 
     * @param uuid 子库存查询ID
     * @return 结果
     */
    @Override
    public int deleteBasStockDetailById(String fbarcode)
    {
        return basStockDetailMapper.deleteBasStockDetailById(fbarcode);
    }

    @Override
    public List<BasStockDetail> selectBasStockDetailList1(String productId) {
        return basStockDetailMapper.selectBasStockDetailList1(productId);
    }

    @Override
    public  List<BasStockDetail> selectBasStockDetailListall() {
        return basStockDetailMapper.selectBasStockDetailListall();
    }
}
